{% extends "learning_logs/base.html" %}

{% block content %}
  <P>Add a new topic:</P>

  <form action="{% url 'learning_logs:new_topic' %}" method="post">
    {% csrf_token %} <!--防止攻击者利用表单来获取对服务器未经授权的访问：跨站请求伪造-->
    {{ form.as_p }}  <!--显示表单-->
    <button name="submit">Add topic</button>
</form>

{% endblock content %}